home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Interactive Media Design Review 1999
/
Interactive Media Design Review 1999.iso
/
pc
/
Demos
/
Bombardier_PC
/
DATACH.CST
/
00200_Script_popUpMenu
< prev
next >
Wrap
Text File
|
1999-03-07
|
2KB
|
67 lines
property thePopLocn, popSpriten, popNamen, mySpriten, faraway, fieldObjn
property thehilitesprite, thePopLocna, topch, rightch
global currentChartName, popbgSpriten
on new me
set mySpriten = the spriteNum of me
set popSpriten = mySpriten + 1
set popbgSpriten = mySpriten - 3
set rightch = the right of sprite (mySpriten - 2)
set topch = the bottom of sprite (mySpriten -2)
set thePopLocn = point(rightch, topch)
set thehilitesprite = mySpriten - 1
set popNamen = "mdl_field"
puppetSprite popSpriten, true
set faraway = point(-1000, -1000)
set the loc of sprite popSpriten = faraway
return me
end
on register me, theObj
set fieldObjn = theObj
return thehilitesprite
end
on mouseDown me
set the member of sprite popSpriten = member popNamen
set the member of sprite popbgSpriten = member popNamen
if currentchartname = "Range_maps" then
set ypos = topch - ( the linecount of member popNamen * the lineHeight of member popNamen)
set thePopLocna = point(rightch, ypos)
set the loc of sprite popSpriten = thePopLocna
set the loc of sprite popbgSpriten = thePopLocna
else
set the loc of sprite popSpriten = thePopLocn
set the loc of sprite popbgSpriten = thePopLocn
end if
-- put "popped - " & thepoploc
updateStage
repeat while the stillDown
checkIfInside fieldObjn
end repeat
set the loc of sprite popSpriten = faraway
set the loc of sprite popbgSpriten = faraway
set name = getPlaneName(fieldObjn)
if name = "" then
nothing
else
disSpecs name
end if
set the loc of sprite popSpriten = faraway
set the loc of sprite popbgSpriten = faraway
updateStage
end
on mouseUp me
nothing
end